package com.akjava.android.box2d;

public class JBodyData{
	public float half_width;
	public float half_height;
	public int id;
	public float angle;
	public JBodyData(){
		
	}
	public JBodyData(int id,float half_width,float half_height){
		this.id=id;
		this.half_width=half_width;
		this.half_height=half_height;
	}
	
	
	public static JBodyData createBox(Box2dControler controler,float x,float y,float width,float height){
		int id=controler.createBox(x, y, width, height);
		return new JBodyData(id,width/2,height/2);
	}
	public static JBodyData createBox(Box2dControler controler,float x,float y,float width,float height,float density,float restitution,float friction ){
		int id=controler.createBox2(x, y, width, height,density,restitution,friction);
		return new JBodyData(id,width/2,height/2);
	}
}
